Skip to content

Add Symfony 4 support #19

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Dec 20, 2017
Merged

Conversation

bocharsky-bw
Copy link
Member

This PR is a blocker for php-translation/symfony-bundle#145

@bocharsky-bw bocharsky-bw changed the title Fix deprecations: Inject translation reader instead of loader Add Symfony 4 support Dec 16, 2017
use Symfony\Component\Translation\MessageCatalogue;
use Symfony\Component\Translation\MessageCatalogueInterface;
use Symfony\Component\Translation\Reader\TranslationReader;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This class does not exist in sf 3.x.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Nyholm that's an interesting case :) TranslationReader does exist since 3.4, but TranslationLoader is deprecated since 3.4 and exists only until 4.0. So, with TranslationReader we can continue supporting the latest version of 3.x and the new versions of 4.x. But if you also want to still maintain 2.8, 3.0, 3.1, 3.2, and 3.3 (I see in Travis config you do it now) - we need to write more legacy code to support those versions. So to move forward, I need to know what do you have in mind about it and what is your further strategy for maintenance of this bundle?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A good practice is to support the last 2 LTS versions of symfony. I think we need to write more code here to support both sf 4.0 and sf 2.8.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or alternatively You create 0.5 and say if one wants to use this on sf older than 3.4 it should use 0.3.2. There is not a lot of commits here so this could work.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, That is an option. But Im not sure I want to go down that route. Better to try to support all versions in master.

@bocharsky-bw
Copy link
Member Author

@Nyholm I think this is ready to be merged, wdyt?

Do you mind to fix StyleCI failures in this PR? Or better create another PR?

@Nyholm Nyholm merged commit 01632cd into php-translation:master Dec 20, 2017
@Nyholm
Copy link
Member

Nyholm commented Dec 20, 2017

Thank you!

@bocharsky-bw bocharsky-bw deleted the patch-1 branch December 20, 2017 13:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants